<template lang="pug">
  .clearfix
    //- 仅查看详情时显示
    .clearfix(v-if="!canEditor")
      .clearfix(v-if="moreShebao && moreShebao.length > 0")
        .form-shebao-title.font-16.font-weight 社保信息
        .mb-20(v-for="table of moreShebao")
          include ./formShebaoFilterOnlyView.pug
          Table.beautiful-table(:columns="shebaoThead" :data="table.parsingData" :stripe="true" ref="demoTable")
            .clearfix.pr-24.pl-24.font-14(slot-scope="{ row, index }" slot="leftTitle")
              span(v-if="index === 0") 基数
              span(v-if="index === 1") 比例

      .form-shebao-title.font-16.font-weight 社保记录
      Table.beautiful-table(:columns="shebaojiluThead" :data="recordTableData" :stripe="true" ref="demoTable")
        .clearfix.pl-20.pr-20(slot="footer")
          Page(
            :current="tableComone.pageIndex"
            :total="tableComone.totalRows"
            @on-change="onChangePage"
            @on-page-size-change="onpageSizeChange"
            show-sizer
            placement="top"
            :page-size-opts="[10, 20, 30, 50, 100]"
          )

      .clearfix.text-center.mt-20.mb-20
        Button.mr-10(type="info" @click="handlepageUp") 查看上一页
        //- Button.mr-10(type="info" @click="handleModify") 修改
        Button.mr-10(type="info" @click="handlepageDown" v-if="[12, 13, 123].indexOf(serviceFeeType) !== -1") 查看下一页
        Button(v-if="!isFromRoster" type="info" ghost @click="goEmployeeBookList()") 返回花名册
        Button(v-if="isFromRoster" type="info" ghost @click="goRoster()") 返回员工管理

    //- 新建或修改时显示
    .clearfix(v-if="canEditor")
      .form-shebao-title.font-16.font-weight 社会保险

      include ./formShebaoFilter.pug
      include ./formShebao-dynamic.pug
      include ./formShebaoList.pug

      //- 参保信息设置页面时的按钮
      .clearfix.text-center.mt-20.mb-20(v-if="isInsuranceInfoSet && !canEditor")
        Button.mr-10(type="info" @click="handleSubmit") 保存并显示列表
        Button(type="info" @click="goEmployeeBookList") 返回员工花名册列表

      //- 展示列表时的按钮
      .clearfix.text-center.mt-20.mb-20(v-if="!isEdit")
        Button.mr-10(v-if="!canEditor" type="info" @click="handlepageUp") 上一步
        Button.mr-10(type="info" @click="handleCreat") 新增
        //- Button(type="info" @click="handlepageDown" v-if="[12, 13, 123].indexOf(serviceFeeType) !== -1" :disabled="!isNext || !employeeId") 下一步
        Button.mr-10(type="info" @click="handlepageDown" v-if="([12, 13, 123].indexOf(serviceFeeType) !== -1 && !canEditor) || isCreateNew" :disabled="tableListData.length == 0") 下一步
        Button(v-if="!isFromRoster" type="info" @click="goEmployeeBookList") 返回员工花名册列表
        Button(v-if="isFromRoster" type="info" @click="goRoster") 返回员工管理列表

      //- 新建或修改时的按钮
      //- .clearfix.text-center.mt-20.mb-20(v-else)
      //-   Button.mr-10(type="info" @click="handleSubmit") 保存
      //-   Button(type="info" @click="isEdit = false") 返回社保列表
</template>

<script>
import Mixin from '../EBshebaoMixin.js'
export default {
  name: '',

  mixins: [Mixin],

  props: {
  },

  data () {
    return {}
  },

  watch: {
  },

  created () {
  },

  beforeMount () {

  },

  mounted () {
    // this.getConfig()
  },

  methods: {
  }
}
</script>

<style lang="less" scope>
</style>
